#ifndef SHAPE_H
#define SHAPE_H

#include <stdexcept>
#include <set>
#include <typeinfo>

#include "Point2.h"

class Rectangle;
class Circle;

//abstract collision shape
class Shape{
private:
    Point2 position_;
protected:
    Shape(const Point2& pos);
public:
    void setPos(const Point2& pos);
    const Point2& getPos() const;

    virtual const bool contains(const Point2& p) const = 0;
    virtual const bool overlaps(const Shape* other) const = 0;

    virtual double getArea() const = 0;

    virtual const Rectangle* boundingRect() const = 0;
    //virtual Circle* boundingCircle() const = 0;

    //virtual std::string toString() const;
};

std::ostream& operator<<(std::ostream& os, const Shape& s);


#endif
